using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Text;
using System.Windows.Forms;
using System.IO;

namespace SBPweb.Presentation.Windows.Forms.Host.Controls
{
    public partial class SplashForm : Form
    {

        #region Protected fields

        protected SplashPanel spBack;

        #endregion

        public SplashForm()
        {
            InitializeComponent();
#if DEBUG
            this.TopMost = false;
#endif
            LoadBackground();
        }

        private void LoadBackground()
        {
            FileInfo fI = new FileInfo(string.Format("{0}.Splash.png", Properties.Settings.Default.ApplicationHostName));
            if (fI.Exists)
            {
                BackgroundImage = new Bitmap(fI.FullName);
            }
            this.Size = new Size(BackgroundImage.Size.Width, this.Height);
            this.Opacity = 0.9f;
        }
    }
}
